Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Navigation now works for detail pages.
Main issues solved:
$.mobile.navigate
, use$.mobile.changePage
while it's not depreciatedyou trigger a transition. You trigger the same transition in
parsePage
, the "sort-of-router". So you trigger the same transition two times creating 2 entries in JQM/browser history. Lot of fun on back-clicks...NOTE: I only removed the double transition in the above snippet. All others you need to replace.
3. Can't use
?id=....
parameters with JQM (will work but be chopped off). I have switched to url-encoded/
so your links are correct =#task-detail-page/123456
but the URL loaded will be#task-detail-page%2123456
. Only way possible as I see it, if you want to have bookmark-able links.4. As all your pages exist in a "default" state, I'm doing the following:
#task-detail-page%2123456
#task-detail-page
) existsdata-url
to where we want to go = change from#task-detail-page
to#task-detail-page%2123456
and trigger same transition again